import java.util.Scanner;

public class Range_2161 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        long n,sum=0,cnt=0;
        n=input.nextLong();
        if(n<0)
            n=Math.abs(n);
        if(n==0){
            System.out.println("1 0");
            System.exit(0);
        }
        while(n!=0){
            sum+=n%10;
            n/=10;
            cnt++;
        }
        System.out.print(cnt + " " + sum);
    }
}